import axios from "@/config/request";
import Result from "@/ts/returnType.ts";

const getProvinceStatisticsApi = () : Promise<Result> => {
    return axios({
        url: '/statistics/province',
        method: 'get'
    })
}

const getProvinceAqiStatisticsApi = () : Promise<Result> => {
    return axios({
        url: '/statistics/provinceAqi',
        method: 'get'
    })
}

const getAqiDistributionStatisticsApi = () : Promise<Result> => {
    return axios({
        url: '/statistics/aqiDistribution',
        method: 'get'
    })
}

const getAqiTrendStatisticsApi = () : Promise<Result> => {
    return axios({
        url: '/statistics/aqiTrend',
        method: 'get'
    })
}

const getCoverageStatisticsApi = () : Promise<Result> => {
    return axios({
        url: '/statistics/coverage',
        method: 'get'
    })
}

const getOverallStatisticsApi = () : Promise<Result> => {
    return axios({
        url: '/statistics/overall',
        method: 'get'
    })

}

export { getProvinceStatisticsApi, getAqiDistributionStatisticsApi, getProvinceAqiStatisticsApi,
    getAqiTrendStatisticsApi, getCoverageStatisticsApi, getOverallStatisticsApi}
